func net/http.bodyAllowedForStatus
10 uses
net/http (current package)
response.go#L315: if r1.ContentLength == 0 && !chunked(r1.TransferEncoding) && !contentLengthAlreadySent && bodyAllowedForStatus(r.StatusCode) {
server.go#L1371: if w.handlerDone.Load() && !trailers && !hasTE && bodyAllowedForStatus(w.status) && !header.has("Content-Length") && (!isHEAD || len(p) > 0) {
server.go#L1388: if w.wants10KeepAlive && (isHEAD || hasCL || !bodyAllowedForStatus(w.status)) {
server.go#L1491: if bodyAllowedForStatus(code) {
server.go#L1521: if w.req.Method == "HEAD" || !bodyAllowedForStatus(code) || code == StatusNoContent {
server.go#L1627: return bodyAllowedForStatus(w.status)
transfer.go#L461: func bodyAllowedForStatus(status int) bool {
transfer.go#L484: case !bodyAllowedForStatus(status):
transfer.go#L555: if realLength == -1 && !t.Chunked && bodyAllowedForStatus(t.StatusCode) {
transfer.go#L565: if isResponse && (noResponseBodyExpected(t.RequestMethod) || !bodyAllowedForStatus(t.StatusCode)) {